import { stopTransform, transfrom } from "./action/newTransfrom.js";
//角色设置
import "./role.js";
//初始化
import "./init.js";
//全局事件
import "./globel/init.js";
export var currentState = { role: "" };
export var domg = function (str) {
    return document.querySelector(str);
};
export var app = document.querySelector("#app");
export var role = document.querySelector(".role1");
var p = localStorage.role || "";
export var role1 = document.querySelector(".role1");
export var role2 = document.querySelector(".role2");
export var currentRole = document.querySelector(".role" + p.slice(1));
//#region 窗口大小
export var box = {
    boxW: app.offsetWidth - role.offsetWidth - 6,
    boxH: app.offsetHeight - role.offsetHeight - 6
};
//监听浏览器窗口变化
window.addEventListener("resize", function () {
    box.boxH = app.offsetHeight - role.offsetHeight - 6;
    box.boxW = app.offsetWidth - role.offsetWidth - 6;
});
//#endregion
window.addEventListener("keydown", transfrom);
window.addEventListener("keyup", stopTransform);
window.addEventListener("beforeunload", function () { });
